package com.wn.cloud.seata.entity;

import com.baomidou.mybatisplus.annotation.*;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.math.BigDecimal;

/**
 * @FileName: OrderEntity
 * @Description: TODO
 * @Author: MaWenHao
 * @Created: 2020/4/17 - 15:58
 * @Version: V1.0
 * @Company: 东方微银科技（北京）有限公司
 */
@Data
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@NoArgsConstructor
@AllArgsConstructor
@TableName("t_order")
public class OrderEntity implements Serializable {

    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    private Long userId;

    private Long productId;

    private Integer count;

    private BigDecimal money;

    /**
     * 订单状态0- 创建， 1-完成
     */
    @TableField(fill = FieldFill.INSERT)
    private Integer status;
}
